local meta = FindMetaTable("Entity") 
if not meta then return end

function meta:Class(arg)
	if not arg then return self:GetNWString("Class") or nil		
	else self:SetNWString("Class", arg) end						
end


local oldHealth = meta.Health
local oldSetHealth = meta.SetHealth
function meta:Health(arg)
	local health = oldHealth(self) or nil
	if CLIENT then return health or nil
	elseif SERVER then
		if not arg then return health or nil
		else oldSetHealth(self, arg) end
	end
end

local oldGetMaxHealth = meta.GetMaxHealth
local oldSetMaxHealth = meta.SetMaxHealth
--table.remove(meta, SetMaxHealth)	meta.SetMaxHealth = nil
function meta:MaxHealth(arg)
	if CLIENT then return self:GetNWInt("MaxHealth") or nil
	elseif SERVER then
		if not arg then return self:GetNWInt("MaxHealth") or nil
		else oldSetMaxHealth(self, arg) self:SetNWInt("MaxHealth", arg) end
	end
end

function meta:Mana(arg)
	if CLIENT then return self:GetNWInt("Mana") or nil
	elseif SERVER then
		if arg then self:SetNWInt("Mana", arg)
		else return self:GetNWInt("Mana") or nil end
	end
end

function meta:MaxMana(arg)
	if CLIENT then return self:GetNWInt("MaxMana") or nil
	elseif SERVER then
		if arg then self:SetNWInt("MaxMana", arg)
		else return self:GetNWInt("MaxMana") or nil end
	end
end